Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: add Note of options.stdio into child_process #26604

Closed
wants to merge 1 commit into from

Conversation

koh110
Copy link
Contributor

@koh110 koh110 commented Mar 12, 2019

add Note of options.stdio into child_process.

Ref: #22892 (comment)

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • tests and/or benchmarks are included
  • documentation is changed or added
  • commit message follows commit guidelines

@nodejs-github-bot nodejs-github-bot added child_process Issues and PRs related to the child_process subsystem. doc Issues and PRs related to the documentations. labels Mar 12, 2019
@koh110
Copy link
Contributor Author

koh110 commented Mar 12, 2019

@addaleax @Trott @bzoz That is a continuation #22892. Would you approve it?

doc/api/child_process.md Outdated Show resolved Hide resolved
Copy link
Member

@addaleax addaleax left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

doc/api/child_process.md Outdated Show resolved Hide resolved
Copy link
Contributor

@bzoz bzoz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Passing file descriptors works fine on Windows, its just sockets that are not supported.

@vsemozhetbyt vsemozhetbyt added the windows Issues and PRs related to the Windows platform. label Mar 12, 2019
@koh110
Copy link
Contributor Author

koh110 commented Mar 12, 2019

I see. I think first sentence is better. I thought that file handle and file descriptors are slightly different.
So, I would change Passing sockets does not supported on Windows..
@addaleax @cjihrig @bzoz

@addaleax
Copy link
Member

But in that case it’s probably not right to put it just under this particular type of option? Passing in a net.Socket object, rather than a file descriptor, is invalid on Windows too then, right?

@@ -637,7 +637,8 @@ pipes between the parent and child. The value is one of the following:
occurred).
6. Positive integer - The integer value is interpreted as a file descriptor
that is currently open in the parent process. It is shared with the child
process, similar to how {Stream} objects can be shared.
process, similar to how {Stream} objects can be shared. Passing sockets
does not supported on Windows.
Copy link
Member

@Trott Trott Mar 12, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
does not supported on Windows.
is not supported on Windows.

@koh110
Copy link
Contributor Author

koh110 commented Mar 13, 2019

Windows allow named pipe. I think Passing in a net.Socket object is valid on Windows.
But I feel like that file descriptors might be intelligible phrase more than Passing sockets.
Umm...

It's valid on Windows.
https://github.com/nodejs/node/blob/master/test/common/index.js#L176-L181

require('net').createServer((conn) => {
    stdio: ['ignore', conn, 'ignore']
  });
}).listen(common.PIPE, () => {});

@koh110
Copy link
Contributor Author

koh110 commented Mar 15, 2019

I have no preference. How about this change? @addaleax @cjihrig

@addaleax addaleax added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Mar 16, 2019
@danbev
Copy link
Contributor

danbev commented Mar 19, 2019

Landed in e08ac04.

@danbev danbev closed this Mar 19, 2019
danbev pushed a commit that referenced this pull request Mar 19, 2019
PR-URL: #26604
Refs: #22892 (comment)
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com>
targos pushed a commit to targos/node that referenced this pull request Mar 27, 2019
PR-URL: nodejs#26604
Refs: nodejs#22892 (comment)
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com>
targos pushed a commit that referenced this pull request Mar 27, 2019
PR-URL: #26604
Refs: #22892 (comment)
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com>
BethGriggs pushed a commit that referenced this pull request Apr 17, 2019
PR-URL: #26604
Refs: #22892 (comment)
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
author ready PRs that have at least one approval, no pending requests for changes, and a CI started. child_process Issues and PRs related to the child_process subsystem. doc Issues and PRs related to the documentations. windows Issues and PRs related to the Windows platform.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants